<template>
  <el-dialog
    v-model="props.pictureDialog"
    :title="
      props.pictureForm?.name +
      (props.pictureForm?.type == 1 ? '设备二维码' : '照片') +
      `查看`
    "
    width="30%"
    @close="close"
  >
    <el-image
      style="width: 200px; height: 200px"
      class="picture2"
      :src="props.pictureForm?.val"
      alt=""
    ></el-image>
    <!-- <qrcode-vue class="picture" v-else :value="props.pictureForm?.val" :size="300" level="H" /> -->
  </el-dialog>
</template>
<script setup lang="ts">
import { ref, reactive } from 'vue'
const props = defineProps({
  pictureDialog: Boolean,
  pictureForm: Object
})

const emit = defineEmits(['closePicture'])
const close = () => {
  emit('closePicture')
}
</script>
<style lang="scss" scoped>
.picture {
  transform: translate(120px, 0px);
}

.picture2 {
  display: flex;
  width: 200px;
  height: 200px;
  margin: 0 auto;
}

::v-deep .el-dialog__body {
  text-align: center !important;
}
</style>
